<?php

/**
 * ContactForm class.
 * ContactForm is the data structure for keeping
 * contact form data. It is used by the 'contact' action of 'SiteController'.
 */
class VacancyForm extends CFormModel {

    public $resume_FIO;
    public $resume_email;
    public $resume_phone;
    public $resume_file;

    /**
     * Declares the validation rules.
     */
    public function rules() {
        return array(
            array('resume_FIO, resume_email, resume_phone', 'required'),
            array('resume_file', 'file', 'allowEmpty' => false, 'types' => 'doc, docx, pdf, txt, rtf', 'maxSize' => 1024 * 1024 * 2),
        );
    }

    /**
     * Declares customized attribute labels.
     * If not declared here, an attribute would have a label that is
     * the same as its name with the first letter in upper case.
     */
    public function attributeLabels() {
        return array(
            'resume_FIO' => 'Ф.И.О',
            'resume_email' => 'Email',
            'resume_phone' => 'Телефон',
            'resume_file' => 'Ваше резюме',
        );
    }

}
